﻿<?xml version="1.0" encoding="utf-8"?>
<xs:schema id="StatsDataComponent" targetNamespace="uri:AspNet:StarterKits:TradingCenter:Data" xmlns:mstns="uri:AspNet:StarterKits:TradingCenter:Data" xmlns="uri:AspNet:StarterKits:TradingCenter:Data" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" xmlns:msprop="urn:schemas-microsoft-com:xml-msprop" attributeFormDefault="qualified" elementFormDefault="qualified">
  <xs:annotation>
    <xs:appinfo source="urn:schemas-microsoft-com:xml-msdatasource">
      <DataSource DefaultConnectionIndex="1" FunctionsComponentName="QueriesTableAdapter" Modifier="AutoLayout, AnsiClass, Class, Public" SchemaSerializationMode="IncludeSchema" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
        <Connections>
          <Connection AppSettingsObjectName="Web.config" AppSettingsPropertyName="TradingCenterConnection" IsAppSettingsProperty="true" Modifier="Assembly" Name="TradingCenterConnection (Web.config)" ParameterPrefix="@" PropertyReference="AppConfig.System.Configuration.ConfigurationManager.0.ConnectionStrings.TradingCenterConnection.ConnectionString" Provider="System.Data.SqlClient" />
          <Connection AppSettingsObjectName="Settings" AppSettingsPropertyName="TradingCenterConnectionString" ConnectionStringObject="" IsAppSettingsProperty="true" Modifier="Assembly" Name="TradingCenterConnectionString (Settings)" ParameterPrefix="@" PropertyReference="ApplicationSettings.SpiderMaster.AspNet.TradingSystem.Properties.Settings.GlobalReference.Default.TradingCenterConnectionString" Provider="System.Data.SqlClient" />
        </Connections>
        <Tables>
          <TableAdapter BaseClass="System.ComponentModel.Component" DataAccessorModifier="AutoLayout, AnsiClass, Class, Public" DataAccessorName="StatsDataAdapter" GeneratorDataComponentClassName="StatsDataAdapter" Name="Stats" UserDataComponentName="StatsDataAdapter">
            <MainSource>
              <DbSource ConnectionRef="TradingCenterConnectionString (Settings)" DbObjectName="dbo.TradingCenter_Ads" DbObjectType="Table" FillMethodModifier="Public" FillMethodName="FillAdCounts" GenerateMethods="Both" GenerateShortCommands="true" GeneratorGetMethodName="GetAdCounts" GeneratorSourceName="FillAdCounts" GetMethodModifier="Public" GetMethodName="GetAdCounts" QueryType="Rowset" ScalarCallRetval="System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="true" UserGetMethodName="GetAdCounts" UserSourceName="FillAdCounts">
                <SelectCommand>
                  <DbCommand CommandType="Text" ModifiedByUser="true">
                    <CommandText>
											SELECT     COUNT(*) AS Count, AdStatus AS GroupingIndicator
											FROM         TradingCenter_Ads
											GROUP BY AdStatus
											ORDER BY AdStatus
										</CommandText>
                    <Parameters />
                  </DbCommand>
                </SelectCommand>
              </DbSource>
            </MainSource>
            <Mappings>
              <Mapping SourceColumn="Count" DataSetColumn="Count" />
              <Mapping SourceColumn="GroupingIndicator" DataSetColumn="GroupingIndicator" />
            </Mappings>
            <Sources>
              <DbSource ConnectionRef="TradingCenterConnectionString (Settings)" DbObjectName="[V:\SOURCE\APPLICATION\SpiderMaster.AspNet.TradingSystem.WEBAPPLICATION\APP_DATA\TradingCenterDB.MDF].dbo.CountAdResponsesByStatus" DbObjectType="StoredProcedure" GenerateShortCommands="true" GeneratorSourceName="CountAdResponsesByStatus" Modifier="Public" Name="CountAdResponsesByStatus" QueryType="Scalar" ScalarCallRetval="System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="true" UserGetMethodName="GetDataBy" UserSourceName="CountAdResponsesByStatus">
                <SelectCommand>
                  <DbCommand CommandType="StoredProcedure" ModifiedByUser="false">
                    <CommandText>CountAdResponsesByStatus</CommandText>
                    <Parameters>
                      <Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DbType="Int32" Direction="ReturnValue" ParameterName="@RETURN_VALUE" Precision="10" ProviderType="Int" Scale="0" Size="4" SourceColumnNullMapping="false" SourceVersion="Current" />
                      <Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DbType="Int32" Direction="Input" ParameterName="@AdStatus" Precision="10" ProviderType="Int" Scale="0" Size="4" SourceColumnNullMapping="false" SourceVersion="Current" />
                    </Parameters>
                  </DbCommand>
                </SelectCommand>
              </DbSource>
              <DbSource ConnectionRef="TradingCenterConnectionString (Settings)" DbObjectName="[V:\SOURCE\APPLICATION\SpiderMaster.AspNet.TradingSystem.WEBAPPLICATION\APP_DATA\TradingCenterDB.MDF].dbo.CountAdsByStatus" DbObjectType="StoredProcedure" GenerateShortCommands="true" GeneratorSourceName="CountAdsByStatus" Modifier="Public" Name="CountAdsByStatus" QueryType="Scalar" ScalarCallRetval="System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="true" UserGetMethodName="GetDataBy1" UserSourceName="CountAdsByStatus">
                <SelectCommand>
                  <DbCommand CommandType="StoredProcedure" ModifiedByUser="false">
                    <CommandText>CountAdsByStatus</CommandText>
                    <Parameters>
                      <Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DbType="Int32" Direction="ReturnValue" ParameterName="@RETURN_VALUE" Precision="10" ProviderType="Int" Scale="0" Size="4" SourceColumnNullMapping="false" SourceVersion="Current" />
                      <Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DbType="Int32" Direction="Input" ParameterName="@AdStatus" Precision="10" ProviderType="Int" Scale="0" Size="4" SourceColumnNullMapping="false" SourceVersion="Current" />
                      <Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DbType="DateTime" Direction="Input" ParameterName="@MinDateCreated" Precision="23" ProviderType="DateTime" Scale="3" Size="8" SourceColumnNullMapping="false" SourceVersion="Current" />
                    </Parameters>
                  </DbCommand>
                </SelectCommand>
              </DbSource>
              <DbSource ConnectionRef="TradingCenterConnectionString (Settings)" DbObjectName="[V:\SOURCE\APPLICATION\SpiderMaster.AspNet.TradingSystem.WEBAPPLICATION\APP_DATA\TradingCenterDB.MDF].dbo.CountAdViewsByStatus" DbObjectType="StoredProcedure" GenerateShortCommands="true" GeneratorSourceName="CountAdViewsByStatus" Modifier="Public" Name="CountAdViewsByStatus" QueryType="Scalar" ScalarCallRetval="System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="true" UserGetMethodName="GetDataBy2" UserSourceName="CountAdViewsByStatus">
                <SelectCommand>
                  <DbCommand CommandType="StoredProcedure" ModifiedByUser="false">
                    <CommandText>CountAdViewsByStatus</CommandText>
                    <Parameters>
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="Int32" Direction="ReturnValue" ParameterName="@RETURN_VALUE" Precision="10" Scale="0" Size="4" SourceColumnNullMapping="false" SourceVersion="Current" />
                      <Parameter AllowDbNull="false" AutogeneratedName="" DataSourceName="" DbType="Int32" Direction="Input" ParameterName="@AdStatus" Precision="10" Scale="0" Size="4" SourceColumnNullMapping="false" SourceVersion="Current" />
                    </Parameters>
                  </DbCommand>
                </SelectCommand>
              </DbSource>
              <DbSource ConnectionRef="TradingCenterConnectionString (Settings)" DbObjectName="[V:\SOURCE\APPLICATION\SpiderMaster.AspNet.TradingSystem.WEBAPPLICATION\APP_DATA\TradingCenterDB.MDF].dbo.CountLocations" DbObjectType="StoredProcedure" GenerateShortCommands="true" GeneratorSourceName="CountLocations" Modifier="Public" Name="CountLocations" QueryType="Scalar" ScalarCallRetval="System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="true" UserGetMethodName="GetDataBy3" UserSourceName="CountLocations">
                <SelectCommand>
                  <DbCommand CommandType="StoredProcedure" ModifiedByUser="false">
                    <CommandText>CountLocations</CommandText>
                    <Parameters>
                      <Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DbType="Int32" Direction="ReturnValue" ParameterName="@RETURN_VALUE" Precision="10" ProviderType="Int" Scale="0" Size="4" SourceColumnNullMapping="false" SourceVersion="Current" />
                    </Parameters>
                  </DbCommand>
                </SelectCommand>
              </DbSource>
              <DbSource ConnectionRef="TradingCenterConnectionString (Settings)" DbObjectName="[V:\SOURCE\APPLICATION\SpiderMaster.AspNet.TradingSystem.WEBAPPLICATION\APP_DATA\TradingCenterDB.MDF].dbo.CountMembersByDateRange" DbObjectType="StoredProcedure" GenerateShortCommands="true" GeneratorSourceName="CountMembersByDateRange" Modifier="Public" Name="CountMembersByDateRange" QueryType="Scalar" ScalarCallRetval="System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="true" UserGetMethodName="GetDataBy4" UserSourceName="CountMembersByDateRange">
                <SelectCommand>
                  <DbCommand CommandType="StoredProcedure" ModifiedByUser="true">
                    <CommandText>CountMembersByDateRange</CommandText>
                    <Parameters>
                      <Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DbType="Int32" Direction="ReturnValue" ParameterName="@RETURN_VALUE" Precision="10" ProviderType="Int" Scale="0" Size="4" SourceColumnNullMapping="false" SourceVersion="Current" />
                      <Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DbType="DateTime" Direction="Input" ParameterName="@StartDate" Precision="16" ProviderType="SmallDateTime" Scale="0" Size="4" SourceColumnNullMapping="false" SourceVersion="Current" />
                      <Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DbType="DateTime" Direction="Input" ParameterName="@EndDate" Precision="16" ProviderType="SmallDateTime" Scale="0" Size="4" SourceColumnNullMapping="false" SourceVersion="Current" />
                    </Parameters>
                  </DbCommand>
                </SelectCommand>
              </DbSource>
              <DbSource ConnectionRef="TradingCenterConnectionString (Settings)" DbObjectName="[V:\SOURCE\APPLICATION\SpiderMaster.AspNet.TradingSystem.WEBAPPLICATION\APP_DATA\TradingCenterDB.MDF].dbo.CountTopCategories" DbObjectType="StoredProcedure" GenerateShortCommands="true" GeneratorSourceName="CountTopCategories" Modifier="Public" Name="CountTopCategories" QueryType="Scalar" ScalarCallRetval="System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="true" UserGetMethodName="GetDataBy5" UserSourceName="CountTopCategories">
                <SelectCommand>
                  <DbCommand CommandType="StoredProcedure" ModifiedByUser="false">
                    <CommandText>CountTopCategories</CommandText>
                    <Parameters>
                      <Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DbType="Int32" Direction="ReturnValue" ParameterName="@RETURN_VALUE" Precision="10" ProviderType="Int" Scale="0" Size="4" SourceColumnNullMapping="false" SourceVersion="Current" />
                    </Parameters>
                  </DbCommand>
                </SelectCommand>
              </DbSource>
              <DbSource ConnectionRef="TradingCenterConnectionString (Settings)" DbObjectName="dbo.TradingCenter_Ads" DbObjectType="Table" FillMethodModifier="Public" FillMethodName="FillAdCategoryCountsByStatus" GenerateMethods="Both" GenerateShortCommands="true" GeneratorGetMethodName="GetAdCategoryCountsByStatus" GeneratorSourceName="FillAdCategoryCountsByStatus" GetMethodModifier="Public" GetMethodName="GetAdCategoryCountsByStatus" QueryType="Rowset" ScalarCallRetval="System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="true" UserGetMethodName="GetAdCategoryCountsByStatus" UserSourceName="FillAdCategoryCountsByStatus">
                <SelectCommand>
                  <DbCommand CommandType="Text" ModifiedByUser="true">
                    <CommandText>
											SELECT     COUNT(*) AS Count, CategoryId AS GroupingIndicator
											FROM         TradingCenter_Ads
											GROUP BY CategoryId, AdStatus
											HAVING      (AdStatus = @AdStatus)
											ORDER BY CategoryId
										</CommandText>
                    <Parameters>
                      <Parameter AllowDbNull="false" AutogeneratedName="AdStatus" ColumnName="AdStatus" DataSourceName="TradingCenter.Ads" DataTypeServer="int" DbType="Int32" Direction="Input" ParameterName="AdStatus" Precision="0" Scale="0" Size="4" SourceColumn="AdStatus" SourceColumnNullMapping="false" SourceVersion="Current" />
                    </Parameters>
                  </DbCommand>
                </SelectCommand>
              </DbSource>
            </Sources>
          </TableAdapter>
        </Tables>
        <Sources />
      </DataSource>
    </xs:appinfo>
  </xs:annotation>
  <xs:element name="StatsDataComponent" msdata:IsDataSet="true" msdata:UseCurrentLocale="true" msprop:Generator_DataSetName="StatsDataComponent" msprop:Generator_UserDSName="StatsDataComponent">
    <xs:complexType>
      <xs:choice minOccurs="0" maxOccurs="unbounded">
        <xs:element name="Stats" msprop:Generator_TableClassName="StatsDataTable" msprop:Generator_TableVarName="tableStats" msprop:Generator_TablePropName="Stats" msprop:Generator_RowDeletingName="StatsRowDeleting" msprop:Generator_UserTableName="Stats" msprop:Generator_RowChangingName="StatsRowChanging" msprop:Generator_RowEvHandlerName="StatsRowChangeEventHandler" msprop:Generator_RowDeletedName="StatsRowDeleted" msprop:Generator_RowEvArgName="StatsRowChangeEvent" msprop:Generator_RowChangedName="StatsRowChanged" msprop:Generator_RowClassName="StatsRow">
          <xs:complexType>
            <xs:sequence>
              <xs:element name="Count" msdata:ReadOnly="true" msprop:Generator_ColumnVarNameInTable="columnCount" msprop:Generator_ColumnPropNameInRow="Count" msprop:Generator_ColumnPropNameInTable="CountColumn" msprop:Generator_UserColumnName="Count" type="xs:int" minOccurs="0" />
              <xs:element name="GroupingIndicator" msprop:Generator_ColumnVarNameInTable="columnGroupingIndicator" msprop:Generator_ColumnPropNameInRow="GroupingIndicator" msprop:Generator_ColumnPropNameInTable="GroupingIndicatorColumn" msprop:Generator_UserColumnName="GroupingIndicator" type="xs:int" />
            </xs:sequence>
          </xs:complexType>
        </xs:element>
      </xs:choice>
    </xs:complexType>
  </xs:element>
</xs:schema>